package com.aaa.controller;

import com.aaa.entity.MyReturn;
import com.aaa.service.TestTypeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.List;

@Controller
@RequestMapping("testType")
public class TestTypeController extends BaseController{

    @Autowired
    private TestTypeService testTypeService;

    MyReturn myReturn=new MyReturn();

    /**
    * @Author: WTH
    * @Description: 查询
    * @Date:2022-07-07 09:02
    * @Params:
    */
    @ResponseBody
    @RequestMapping("selectTestType.do")
    public MyReturn selectTestType(){
        List<String> list = testTypeService.selectTestType();
        if(list!=null && list.size()>0){
            myReturn.setData(list);
            return super.getSuccessResult(myReturn);
        }
        return super.getFailResult(myReturn);
    }
}
